<!DOCTYPE html>
<html lang="zh-CN">
<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>企业详情</title>
  <link href="https://cdn.jsdelivr.net/npm/tailwindcss@2.2.19/dist/tailwind.min.css" rel="stylesheet">
  <link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/font-awesome/6.4.0/css/all.min.css">
</head>
<body class="bg-gray-50">
  <div class="max-w-md mx-auto bg-white min-h-screen">
    <div class="p-4 border-b flex items-center">
      <a href="javascript:history.back()" class="mr-2"><i class="fas fa-arrow-left"></i></a>
      <h1 class="text-lg font-semibold">科技智联</h1>
    </div>

    <div class="p-4">
      <div class="flex items-center mb-4">
        <img class="w-16 h-16 rounded-lg object-cover mr-3" src="https://images.unsplash.com/photo-1486406146926-c627a92ad1ab?auto=format&fit=crop&w=120&h=120&q=80">
        <div class="flex-1">
          <div class="font-semibold">科技智联 · B轮</div>
          <div class="text-gray-500 text-sm">上海 · 500-999人 · SaaS</div>
        </div>
        <button id="follow-btn" class="px-3 py-1 border rounded text-blue-600 border-blue-600">关注</button>
      </div>

      <div class="mb-4">
        <div class="font-semibold mb-1">公司简介</div>
        <div class="text-gray-600 text-sm">专注企业数字化转型的科技公司，核心产品覆盖多行业，重视研发投入。</div>
      </div>

      <div class="mb-4">
        <div class="font-semibold mb-2">在招职位</div>
        <div class="space-y-2">
          <a class="block p-3 border rounded" href="#">
            <div class="font-medium">高级前端工程师</div>
            <div class="text-gray-500 text-sm">15k-30k · 上海 · 3-5年</div>
          </a>
          <a class="block p-3 border rounded" href="#">
            <div class="font-medium">全栈工程师</div>
            <div class="text-gray-500 text-sm">25k-45k · 上海 · 5-10年</div>
          </a>
        </div>
      </div>

      <div class="mt-6">
        <button onclick="history.back()" class="w-full py-3 bg-blue-600 text-white rounded">返回</button>
      </div>
    </div>
  </div>

  <script>
    const followBtn = document.getElementById('follow-btn');
    function renderFollow(){
      const followed = JSON.parse(localStorage.getItem('followedCompanies') || '[]');
      const isFollowed = followed.includes('科技智联');
      followBtn.textContent = isFollowed ? '已关注' : '关注';
      followBtn.className = isFollowed ? 'px-3 py-1 rounded bg-gray-100 text-gray-500' : 'px-3 py-1 border rounded text-blue-600 border-blue-600';
    }
    followBtn.addEventListener('click', () => {
      const key = 'followedCompanies';
      const set = new Set(JSON.parse(localStorage.getItem(key) || '[]'));
      if (set.has('科技智联')) set.delete('科技智联'); else set.add('科技智联');
      localStorage.setItem(key, JSON.stringify(Array.from(set)));
      renderFollow();
    });
    renderFollow();
  </script>
</body>
</html> 